* {
    padding: 0;
    margin: 0;
}

.sub-header-2 {
    background-position: center;
    background-size: cover;
    text-align: center;
    color: rgb(0, 0, 0);
}

body {
    height: 100%;
    margin: 0;
    display: flex;
    flex-direction: column;
    background-color: #12181b;
}

.navigation {
    font-family: "Poppins", sans-serif;
}

main {
    font-family: "Itim", cursive;
    flex: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
}

.title {
    color: white;
    text-align: center;
    font-size: 40px;
}

.display {
    color: white;
    font-size: 25px;
    text-align: center;
    margin-top: 1em;
    margin-bottom: 1em;
}

.hide {
    display: none;
}

.container {
    margin: 0 auto;
    display: grid;
    grid-template-columns: 33% 33% 33%;
    grid-template-rows: 33% 33% 33%;
    max-width: 300px;
}

.tile {
    border: 1px solid white;
    min-width: 100px;
    min-height: 100px;
    display: flex;
    justify-content: center;
    align-items: center;
    font-size: 50px;
    cursor: pointer;
}

.playerX {
    color: #09c372;
}

.playerO {
    color: #498afb;
}

.controls {
    display: flex;
    flex-direction: row;
    justify-content: center;
    align-items: center;
}

.controls button {
    margin-top: 20px;
    color: white;
    padding: 10 30px;
    border-radius: 8px;
    border: none;
    font-size: 17px;
    font-weight: bold;
    font-style: italic;
    cursor: pointer;
}

.custom-toast {
    position: fixed;
    top: 20px;
    left: 50%;
    transform: translateX(-50%);
    min-width: 250px;
    padding: 15px 20px;
    border-radius: 6px;
    font-size: 18px;
    font-weight: bold;
    color: white;
    display: none;
    box-shadow: 0px 4px 8px rgba(0, 0, 0, 0.2);
    z-index: 1050;
    animation: fadeInOut 3s ease-in-out;
}

.toast-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-family: "Itim", cursive;
    color: black;
}

#notificationText {
    flex: 1;
    text-align: center;
}

.custom-toast.success {
    background-color: lightgreen;
}

.custom-toast.warning {
    background-color: #ebc75d;
}

.custom-toast.error {
    background-color: #ff3860;
}

button {
    background: none;
    border: none;
    color: white;
    font-size: 20px;
    cursor: pointer;
}

/* Animation */
@keyframes fadeInOut {
    0% {
        opacity: 0;
        transform: translateX(-50%) translateY(-10px);
    }

    20% {
        opacity: 1;
        transform: translateX(-50%) translateY(0);
    }

    80% {
        opacity: 1;
        transform: translateX(-50%) translateY(0);
    }

    100% {
        opacity: 0;
        transform: translateX(-50%) translateY(-10px);
    }
}

#reset {
    background-color: #ff3860;
    transition: 1s;
}

#reset:hover {
    background-color: #ff0033;
}

.footer {
    position: absolute;
    margin-top: 80px;
    bottom: 0;
    width: 100%;
}

@media (max-width: 900px) {
    .title {
        font-size: 20px;
    }

    .tile {
        min-width: 90px;
        min-height: 90px;
        font-size: 45px;
    }

    .display {
        font-size: 20px;
        text-align: center;
        margin-top: 1em;
        margin-bottom: 1em;
    }

    .controls button {
        margin-top: 20px;
        padding: 10 30px;
        font-size: 14px;
    }

    .custom-toast {
        top: 20px;
        left: 50%;
        min-width: 250px;
        padding: 15px 20px;
        border-radius: 6px;
        font-size: 18px;
    }
}

@media (max-width: 500px) {
    .tile {
        min-width: 80px;
        min-height: 80px;
        font-size: 40px;
    }

    .custom-toast {
        top: 110px;
    }
}